home *** CD-ROM | disk | FTP | other *** search
/ Amiga Format CD 31 / Amiga Format CD31 (1998-09-02)(Future Publishing)(GB)(Track 1 of 2)[!][issue 1998-10].iso / -coverdisks- / 115a / ppt / rexx / empty.prx < prev    next >
Text File  |  1998-07-29  |  859b  |  40 lines

  1. /*
  2.     This is an empty script for you to take and copy.
  3.  
  4.     $Id: empty.prx 1.1 1997/05/15 00:13:01 jj Exp jj $
  5. */
  6.  
  7. /*-------------------------------------------------------------------*/
  8. /*  I suggest you use this header as-is and add your own code below  */
  9.  
  10. OPTIONS RESULTS
  11. SIGNAL ON ERROR
  12. IF ADDRESS() = REXX THEN DO
  13.     startedfromcli = 1
  14.     ADDRESS PPT
  15. END
  16. ELSE DO
  17.     startedfromcli = 0
  18.     ADDRESS PPT
  19. END
  20. RESULT = 'no result'
  21.  
  22. /*-------------------------------------------------------------------*/
  23. /* Add your code here */
  24.  
  25. EXIT 0
  26.  
  27. /*-------------------------------------------------------------------*/
  28. /* Again, keep this part intact. This is the error handler. */
  29. ERROR :
  30. returncode = RC
  31. IF startedfromcli = 1 THEN DO
  32.     SAY 'ERROR ' returncode ' on line ' SIGL ': ' RC2
  33.     PPT_TO_BACK
  34. END
  35. ELSE
  36.     SHOWERROR '"'RC2'"' SIGL
  37. EXIT returncode
  38.  
  39.  
  40.